﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using LGE;
using Microsoft.Xna.Framework.Graphics;
using Microsoft.Xna.Framework;

namespace EggCatcher
{
    class Basket : GameObject
    {
        int velocity = 10;

        public Basket(GameScreen gs)
            : base(gs, Engine.Load<Texture2D>("Images\\cesto"))
        {
        }

        public override void Update(Microsoft.Xna.Framework.GameTime gameTime)
        {
            if (position.X < radius) position = new Vector2(radius, position.Y);
            if (position.X > Engine.viewport.Width - radius) position = new Vector2(Engine.viewport.Width - radius, position.Y);
        }

        public void Move(Vector2 d)
        {
            position += d * velocity;
        }
    }
}
